package com.gcxy.dto;

/**
 * @Author QingYuQiao
 * @date 2023/12/18  16:25
 */

import io.swagger.annotations.ApiModelProperty;
import lombok.Builder;
import lombok.Data;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * 牧场DTO 参数校验
 */
@Data
@Builder
public class RanchDTO {

    @ApiModelProperty(value = "唯一,牧场名称")
    @NotNull(message = "牧场名称不能为空")
    @Length(max = 100 , message = "牧场名称不能超过100个字符")
    private String ranchName;


    @ApiModelProperty(value = "场地规模(100~999999)")
    @NotNull(message = "场地规模不能为空")
    @Range(max = 999999 , message =  "场地规模不能超过999999")
    private Integer fieldScale;


    @ApiModelProperty(value = "养殖规模(0~999999)")
    @NotNull(message = "养殖规模不能为空")
    @Range(max = 999999 , message =  "养殖规模不能超过999999")
    private Integer feedScale;

    @ApiModelProperty(value = "省")
    @NotNull(message = "省不能为空")
    private String province;

    @ApiModelProperty(value = "市")
    @NotNull(message = "市不能为空")
    private String city;

    @ApiModelProperty(value = "县")
    @NotNull(message = "县不能为空")
    private String county;

    @ApiModelProperty(value = "详细地址")
    @NotNull(message = "详细地址不能为空")
    private String addrDetail;

    @ApiModelProperty(value = "经度")
    @NotNull(message = "经度不能为空")
    private BigDecimal longitude;

    @ApiModelProperty(value = "纬度")
    @NotNull(message = "纬度不能为空")
    private BigDecimal latitude;

    @ApiModelProperty(value = "字典值编号（关联具体牲畜品种）")
    @NotNull(message =  "字典值编号不能为空")
    private Integer valId;
}
